home *** CD-ROM | disk | FTP | other *** search
/ Amiga Developer CD 2.1 / Amiga Developer CD v2.1.iso / NDK / NDK_3.5 / Tools / ReActor / Examples / EuroCalc / catcomp.srx next >
Encoding:
Text File  |  1999-10-27  |  1.1 KB  |  39 lines

  1. /*
  2.     catcomp.srx
  3.  
  4.     Compile a catalog description file to an C header file.
  5.  
  6.     © 1996/97 HAAGE & PARTNER GmbH
  7.  
  8.     $VER catcomp.srx 1.1 (14.2.97)
  9.  
  10.     Warning: The function "GetString()" which will be generated by catcomp and
  11.     used by setting "#define CATCOMP_CODE" ever uses the global symbol
  12.     _LocaleBase for calling the function "GetCatalogStr()" from locale.library
  13.     and not the expression li->li_LocaleBase.
  14.  
  15. */
  16.  
  17. /* Don't forget the point '.' at the end      \/        */
  18. PARSE ARG '"' filename '"' '"' projectname '"' .
  19.  
  20. /* Replace suffix ".cd" by ".h" */
  21. objectname = LEFT(filename,LASTPOS('.cd',filename)-1)||"CD.h"
  22. objectname2 = LEFT(filename,LASTPOS('.cd',filename)-1)||"CD.asm"
  23.  
  24. SAY ""
  25. SAY "Catcomp Script ©1996/97 HAAGE & PARTNER GmbH"
  26. SAY "Compile "||filename||" to header "||objectname||"."
  27.  
  28. /* set object file of catalog file */
  29. OBJECTS filename objectname objectname2
  30.  
  31. /* compile */
  32. ADDRESS COMMAND "catcomp "||filename||" CFILE "||objectname||" ASMFILE "||objectname2||" XDEF"
  33.  
  34. /* add object file to project */
  35. ADDFILE objectname QUIET
  36. ADDFILE objectname2 QUIET
  37.  
  38. SAY "Done."
  39.